4 examples for git branch

{{ score }}
  # delete a local branch (to delete a remote branch refer to 'bro git push')
git branch -D feature/cool-thing
        
{{ score }}
  # List all branches, both locally and on remotes
# NOTE: If you haven't used `git fetch` first, you won't see newly-created remote branches
git branch -a
        
{{ score }}
  # Rename a branch
git branch -m lolbranch featurebranch
        
{{ score }}
  #

# Move (by force) a branch to another point in the commit tree. This example moves the local develop branch three
# commits back from HEAD.
#
# Note that you cannot move the branch you are currently in.
git branch -f develop HEAD~3